<?php
namespace Hive\Leave;
/**
 * Leave Request Object
 *
 *
 * @author Yassir OUBAHA
 * @package Hive\Leave
 * @license
 *
 * @property string	$idusr			Employee code (11)
 * @property string	$requestid		Request language (5)
 * @property string	$sent_date		Creation date (10)
 * @property string	$start_date		Start date (10)
 * @property string	$full_start		bool to set hal day (1)
 * @property string	$end_date		End date (10)
 * @property string	$full_end		bool to set hal day (1)
 * @property string	$type			Request type (11)
 * @property string	$status		Request status (11)
 * @property string	$duration		duration (11)
 * @property string	$comment		commentary (500)
 */
class Request extends \Fox\Object\Versioned
{

}
\Fox\Dao::infos(Request::className(),new \Fox\Object\Info('leave_requests', \Fox\Databases::DB_APP)
)->addAutoIncrementField("$requestid");

\Fox\Object\Links::add(\Fox\Dao::link(Request\Type::className(), Request\Type::LINK_TYPE)
		->to(Request::className(), Request::LINK_REQUEST_TYPE)
		->on('type')
		->versionFrom());

\Fox\Object\Links::add(\Fox\Dao::link(Request\Status::className(), Request\Status::LINK_STATUS)
		->to(Request::className(), Request::LINK_REQUEST_STATUS)
		->on('status')
		->versionFrom());